﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace WaiGaoQiaoWeb.Models
{
    public class RuleVM
    {
        /// <summary>
        /// Id
        /// </summary>

        public int ID { get; set; }
        /// <summary>
        /// 规则名称
        /// </summary>
        [DisplayName("规则名称")]
        [Required(ErrorMessage = "物品领用规则名称不能为空")]
        public string ArticleName { get; set; }
        /// <summary>
        /// 几个月
        /// </summary>
        [DisplayName("月数")]
        [RegularExpression(@"^[1-9]\d*$", ErrorMessage = "卡序列号必须是大于0的整数")]
        [Required(ErrorMessage = "月数不能为空")]
        public int Month { get; set; }
        /// <summary>
        /// 备注
        /// </summary>
        [DisplayName("备注")]
        public string Remark { get; set; }
    }
}